import { Entity, Column, PrimaryGeneratedColumn } from 'typeorm';
import { tb_apigroup_entity } from './tb_apigroup.entity.js';


@Entity('tb_apiitem')
export   class tb_apiitem_enity {
//  "id" INTEGER NOT NULL,
// "url" TEXT,
// "name" TEXT,
// "method" TEXT,
// "request" TEXT,
// "response" TEXT,
// "project_code" TEXT,
// "tagid" INTEGER,


  @PrimaryGeneratedColumn()
  id: number;
  @Column()
  name: string;
  @Column()
  url: string;

  @Column({name:"method"})
  method: string;

  @Column({name:"request"})
  request: string;
  @Column({name:"response"})
  response: string;
  @Column({name:"project_code"})
  projectCode: string;

  @Column({name:"tagid"})
  tagid: number;
  @Column({name:"tagname"})
  tagname: string;
  @Column({name:"parameters"})
  parameters: string;






  constructor(_obj: Partial<tb_apiitem_enity>) {
    this.id = _obj?.id;
    this.name = _obj?.name;
    this.method = _obj?.method;
    this.request = _obj?.request;
    this.response = _obj?.response;
    this.projectCode = _obj?.projectCode;
      this.url=_obj?.url;
    this.tagid = _obj?.tagid;
    this.tagname = _obj?.tagname;
    this.parameters = _obj?.parameters;

  }
}
